Skip to main content
This forum is closed to new posts and responses. Individual names altered for privacy purposes. The information contained in this website is provided for informational purposes only and should not be construed as a forum for customer support requests. Any customer support requests should be directed to the official HCL customer support channels below:

HCL Software Customer Support Portal for U.S. Federal Government clients
HCL Software Customer Support Portal

HCL Notes/Domino 8.5 Forum (includes Notes Traveler)

HCL Notes/Domino 8.5 Forum (includes Notes Traveler)

Previous Next
Subject: Excel Automation object error(213)
Feedback Type: Problem
Product Area: Domino Server
Technical Area: Application Development
Platform: Windows
Release: 8.5.1
Reproducible: -Reproducibility-

Bit worried about this one and I've looked around and found lots of posts with similar problems, but not many of them have fixes.

Windows 2008 server and Domino running as a service (as it should). I've installed Office 2007 on the server to run an export. The code is executed from a web browser, but throws the following error when it tries to save the excel spreadsheet.

"OLE: Automation object error(213)"

It works fine when I try to run it from a Lotus Notes Client locally.

I've changed the Runtime security level to "2. Allow restricted operations without success", "1. Do not allow restricted operations" does not work at all, it fails much earlier and although I have tried using "3. Allo restricted operations with full administration rights", I don't think it's necessary, so have left it on "2. Allow restricted operations".

Code is as follows:

Dim session As NotesSession
Dim db As NotesDatabase
Dim doc As NotesDocument

Set session = New NotesSession
Set db = session.currentDatabase

Dim myobject As Variant
Dim mysheet As Variant

Set myobject = createObject("Excel.application.12") ' 12 for version 12 (2007) otherwise just Excel.application

myobject.workbooks.add

Set mysheet = myobject.workbooks(1).Worksheets(1)

mysheet.name = "Review"

mysheet.cells(2, 5).value="Transfer to Excel"
mysheet.cells(2, 5).Font.Size=14
mysheet.cells(2, 5).Font.ColorIndex=3
mysheet.cells(2, 5).Font.Bold = True

Dim fmlaval As Variant

mysheet.cells.Columns.autofit

'Debugging shows that it fails on the next line
mysheet.SaveAs "C:\Downloads\test","56" ' "56" means 97 to 2003 version

myobject.visible=True

myobject.quit
Set myobject = Nothing ' free up the memory


Feedback number WEBB84N23H created by ~Hal Dwovelukonynivu on 04/19/2010

Status: Open
Comments:

Excel Automation object error(213) (~Hal Dwovelukon... 19.Apr.10)
. . Security and Domino access to Excel... (~Hal Dwovelukon... 19.Apr.10)
. . . . Excel File Format (~Hal Dwovelukon... 19.Apr.10)
. . . . . . Drowning here... (~Hal Dwovelukon... 23.Apr.10)
. . . . . . . . Similar issues (~Fritz Quethipi... 12.Jun.12)
. . . . . . . . . . Mine was far easier (~Fritz Quethipi... 14.Jun.12)
. . This worked for me (~Miriam Asajipy... 29.Apr.10)




Printer-friendly

Search this forum

Member Tools


RSS Feeds

 RSS feedsRSS
All forum posts RSS
All main topics RSS